<?php  

class pegawai extends CI_Controller {
 
	var $limit=10;
	var $offset=10;	
	
	function index($limit='',$offset=''){
		$this->load->model("init"); 
		$this->init->getLasturl();
		if($this->session->userdata('LOGIN')=='TRUE'){
		$this->load->model("listpegawai_model"); 
		$data['judul']='Table Pegawai';
		 
		/*----------------*/
		$data['query']=$this->listpegawai_model->getListPegawai();
		$data['view']='pegawai/data_pegawai';
		$this->load->view('index',$data); } else {
		redirect('home/loginPage');		
		}
	}
	function search($limit='',$offset=''){
	 	$this->load->model("pegawai_model"); 
		 
 
		$data['query']=$this->pegawai_model->getListCuti();
		$this->load->view('cuti/hist_cuti',$data);
	}
 
	 
	function detailPegawai($id=''){
			$this->load->model("pegawai_model"); 
			$this->pegawai_model->detailPegawai($id);
				
	}
 
	 
	 
	
}

/* End of file welcome.php */
/* Location: ./application/controllers/welcome.php */